import request from "@/utils/request";
import { City, District, Province } from "./type";

/**获取省份列表 */
export function fetchProvinceList() {
  return request.get<Province, true>('/cupid/province/list')
}

/**获取市列表 */
export function fetchCityList(provinceCode?: string) {
  return request.get<City, true>('/cupid/city/list', { provinceCode })
}

/**获取区县列表 */
export function fetchDistrictList(cityCode?: string) {
  return request.get<District, true>('/cupid/district/list', { cityCode })
}